package com.lordjoe.collectiveintelligence;

/**
 * com.lordjoe.collectiveintelligence.PairId
 *  This is a class that uses a pair of object as
 * a single ID -
 * NOTE it may break if the items change their hash code
 * @author Steve Lewis
 * @date Feb 24, 2009
 */
public class PairId<T>  extends CollectiveId
{
    public static PairId[] EMPTY_ARRAY = {};
    public static Class THIS_CLASS = PairId.class;


    public PairId(T i1,T i2)
    {
        super(i1,i2);
    }

    public T getItem1()
    {
        return (T)getItems()[0];
    }

    public T getItem2()
    {
        return (T)getItems()[1];
    }

}
